﻿using System;

class LetterIndices
{
    static void Main()
    {
        char[] alphabet = { 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z' };
        string consoleInput = Console.ReadLine();

        for (int i = 0; i < consoleInput.Length; i++)
        {
            char letter = consoleInput[i];
            int index = MyBinarySearch(alphabet, 0, 25, letter);
            Console.WriteLine("'{0}' --> [{1}]", letter, index);
        }
    }

    public static int MyBinarySearch(char[] arr, int min, int max, int key)
    {
        while (max >= min)
        {
            int mid = (min + max) / 2;

            if (arr[mid] < key)
            {
                min = mid + 1;
            }
            else if (arr[mid] > key)
            {
                max = mid - 1;
            }
            else
            {
                return mid;
            }
        }

        return -1;
    }
}
